﻿using System.ComponentModel.Composition;
using System.Windows;
using System.Windows.Media;
using Microsoft.VisualStudio.Text.Classification;
using Microsoft.VisualStudio.Utilities;

namespace Behaviorize.TextEditor.Coloring
{
	[Export(typeof (EditorFormatDefinition))]
	[ClassificationType(ClassificationTypeNames = "keyword")]
	[Name("keyword")]
	[UserVisible(false)]
	[Order(Before = Priority.Default)]
	internal sealed class KeywordFormat : ClassificationFormatDefinition
	{
		public KeywordFormat()
		{
			DisplayName = "Keyword";
			ForegroundColor = Colors.Blue;
		}
	}

	[Export(typeof(EditorFormatDefinition))]
	[ClassificationType(ClassificationTypeNames = "erroneous")]
	[Name("erroneous")]
	[UserVisible(false)]
	[Order(Before = Priority.Default)]
	internal sealed class ErroneousFormat : ClassificationFormatDefinition
	{
		public ErroneousFormat()
		{
			DisplayName = "Erroneous";
			ForegroundBrush = Brushes.Silver;
		}
	}

	[Export(typeof(EditorFormatDefinition))]
	[ClassificationType(ClassificationTypeNames = "examplepipe")]
	[Name("examplepipe")]
	[UserVisible(false)]
	[Order(Before = Priority.Default)]
	internal sealed class ExamplePipeFormat : ClassificationFormatDefinition
	{
		public ExamplePipeFormat()
		{
			DisplayName = "Example table pipe";
			ForegroundColor = Colors.DarkGray;
		}
	}

	[Export(typeof(EditorFormatDefinition))]
	[ClassificationType(ClassificationTypeNames = "exampleusage")]
	[Name("exampleusage")]
	[UserVisible(false)]
	[Order(Before = Priority.Default)]
	internal sealed class ExampleUsageFormat : ClassificationFormatDefinition
	{
		public ExampleUsageFormat()
		{
			DisplayName = "Example usage";
			IsBold = true;
		}
	}
}